QuickTime 3 Reference

| Previous | Chapter contents | Chapter top | Section top | Next |

Exporting Text

This section describes new functions provided by text export components.

TextExportGetDisplayData

The TextExportGetDisplayData function retrieves text display information for the current sample in the specified text export component.

pascal ComponentResult TextExportGetDisplayData (
                     TextExportComponent ci,
                     TextDisplayData *textDisplay);
ci
Specifies the text export component for this operation. Applications obtain this reference from the Component Manager's OpenComponent function.
textDisplay
Contains a pointer to a text display data structure. On return, this structure contains the display settings of the current text sample. For more information, see "Text Display Data Structure" .

DISCUSSION

You call this function to retrieve the text display data structure for a text sample. The text display data structure contains the formatting information for the text sample. When the text export component exports a text sample, it uses the information in this structure to generate the appropriate text descriptors for the sample. Likewise, when the text import component imports a text sample, it sets the appropriate fields in the text display data structure based on the sample's text descriptors.

RESULT CODES

Component Manager errors, as documented in Inside Macintosh: More Macintosh Toolbox .

TextExportGetTimeFraction

The TextExportGetTimeFraction function retrieves the time scale the specified text export component uses to calculate time stamps.

pascal ComponentResult TextExportGetTimeFraction (
                     TextExportComponent ci,
                     long *movieTimeFraction);
ci
Specifies the text export component for this operation.
movieTimeFraction
Contains a pointer to a 32-bit integer. On return, this integer contains the time scale used in the fractional part of time stamps.

DISCUSSION

You call this function to retrieve the time scale used by the text export component to calculate the fractional part of time stamps. You set a text component's time scale by specifying it in the Text Export Settings dialog or by calling the TextExportSetTimeFraction function.

RESULT CODES

Component Manager errors, as documented in Inside Macintosh: More Macintosh Toolbox .

TextExportSetTimeFraction

The TextExportSetTimeFraction function set the time scale the specified text export component uses to calculate time stamps.

pascal ComponentResult TextExportSetTimeFraction (
                     TextExportComponent ci,
                     long movieTimeFraction);
ci
Specifies the text export component for this operation.
movieTimeFraction
Specifies the time scale used in the fractional part of time stamps. The value should be between 1 and 10000, inclusive.

DISCUSSION

You call this function to set the time scale used by the text export component to calculate the fractional part of time stamps. You can also set a text component's time scale by specifying it in the Text Export Settings dialog. You can retrieve a text component's time scale by calling the TextExportGetTimeFraction function.

RESULT CODES

Component Manager errors, as documented in Inside Macintosh: More Macintosh Toolbox .

TextExportGetSettings

The TextExportGetSettings function retrieves the value of the text export option for the specified text export component.

pascal ComponentResult TextExportGetSettings (
                     TextExportComponent ci,
                     long *setting);
ci
Specifies the text export component for this operation.
setting
Contains a pointer to a 32-bit integer. On return, this integer contains a constant that represents the current value of the text export option. Possible values are kMovieExportTextOnly , kMovieExportAbsoluteTime , and kMovieExportRelativeTime . For more information, see "Text Export Options" .

DISCUSSION

You call this function when exporting text to retrieve the current value of the text export option for the specified text export component. If the retrieved text export option is kMovieExportTextOnly , the text export component exports text without time descriptors or time stamps. If the retrieved text export option is either kMovieExportAbsoluteTime or kMovieExportRelativeTime , the text export component exports text along with its text descriptors and time stamps.

RESULT CODES

Component Manager errors, as documented in Inside Macintosh: More Macintosh Toolbox .

TextExportSetSettings

The TextExportSetSettings function sets the value of the text export option for the specified text export component.

pascal ComponentResult TextExportSetSettings (
                     TextExportComponent ci,
                     long setting);
ci
Specifies the text export component for this operation.
setting
Specifies a constant that represents the current value of the text export option. Possible values are kMovieExportTextOnly , kMovieExportAbsoluteTime , and kMovieExportRelativeTime . For more information, see "Text Export Options" .

DISCUSSION

You call this function when exporting text to set the value of the text export option for the specified text export component. To export text only, without time descriptors or time stamps, you should set the setting parameter to kMovieExportTextOnly . To export text with text descriptors and absolute time stamps, you should set the setting parameter to kMovieExportAbsoluteTime . To export text with text descriptors and relative time stamps, you should set the setting parameter to kMovieExportRelativeTime .

RESULT CODES

Component Manager errors, as documented in Inside Macintosh: More Macintosh Toolbox .


© 1997 Apple Computer, Inc.

| Previous | Chapter contents | Chapter top | Section top | Next |